package com.hc.rabbit;

import org.springframework.amqp.core.Queue;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.stereotype.Component;

@Configuration//配置类
public class RabbitMQConfig {

    @Bean
    public Queue queue1(){
        return new Queue("mail_queue",true);

    }
}
